import React from 'react';
import { notification } from 'antd';
import ReactQuill from 'react-quill';
import 'react-quill/dist/quill.snow.css';

export default class PateoSimditor extends React.Component {
  state = {
    value: '',
  };
  // , delta, source, editor
  handleChange = (content) => {
    this.setState({
      value: content,
    });
  };

  prompt = () => {
    notification.open({
      message: 'We got value:',
      description: <span dangerouslySetInnerHTML={{ __html: this.state.value }} />,
    });
  };

  render() {
    return (
      <ReactQuill
        value={this.state.value}
        onChange={this.handleChange}
      />
    );
  }
}
